<?php
/***********************************************************************
 * @package    IvanEngine
 * @subpackage Plugin
 * @author     Ivan <ivanzx@msn.com>
 * @created    2010-05-23
 ***********************************************************************/
if(defined("IVANENGINE_ACTION_GUARD"))
    die("Redefinition macro in :".__FILE__."(".__LINE__.")");
define("IVANENGINE_ACTION_GUARD", true);

class CActionGuard extends CAction
{
    public function DoIndex(CRequest & $request)
    {
        return false;
    }
    
    public function DoLogin(CRequest & $request)
    {
        $this->SetLayout(null);
        $this->GetView()->SetWindow('login', false);
        $this->GetView()->SetRenderMode(CView::RM_HTML);
        $this->Set('LastPlugin', $request->GetParameter('LastPlugin'));
        $this->Set('LastAction', $request->GetParameter('LastAction'));
    }
    
    public function DoDoLogin(CRequest & $request)
    {
        $this->SetLayout(null);
        $this->GetView()->SetWindow('login');
        $this->GetView()->SetRenderMode(CView::RM_APPEND);
        echo '<script>alert("DoLogin");</script>';
    }
}

?>
